package com.test.test.controller;

import com.test.test.entity.student;
import com.test.test.mapper.StudentMapper;
import com.test.test.service.StudentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class studentcontroller {

    @Autowired
    private StudentMapper studentMapper;

    @RequestMapping("/123")
    public st getname(){
        return new st("张三",18,"男","2019080910001");
    }

    @RequestMapping("/A")
    public List<student> getStudent(){
        return studentMapper.findAll();
    }
}
